package com.anuo.app.modules.coach.dao;

import com.anuo.app.common.persistence.MyBatisDao;
import com.anuo.app.modules.coach.entity.*;
import com.anuo.app.modules.user.entity.UserAccount;
import com.anuo.app.modules.venue.entity.Venue;

import java.util.List;

@MyBatisDao
public interface StudentDao {
    void insertCoachComment(CoachComment coachComment);
    int getCoachCommentListCount(CoachFilter coachFilter);
    List<CoachComment> getCoachCommentList(CoachFilter coachFilter);
    int getStudentMoney();
    List<CoachStudentmoney> getStudentBalanceRecords(CoachStudentmoney coachStudentmoney);
    CoachCourse getCourseAndIsJoined(UserAccount userAccount);
    void deleteCoachCommentBatch(List<CoachComment> coachCommentList);
    List<Venue> getLatestVenueVisit();
    CoachCourse getCoachCourse(CoachCourse coachCourse);
    CoachCourse getCoachCourseById(String courseId);
    CoachStudentmoney getStudentBalance(CoachStudentmoney coachStudentmoney);
    boolean isJoinedCourse(CoachCoursejoin coachCoursejoin);

    /**
     * 是否存在报名记录
     * @param coachCoursejoin
     * @return
     */
    boolean isExistJoinedRecord(CoachCoursejoin coachCoursejoin);
    int getJoinedStudentCount(CoachCoursejoin coachCoursejoin);
    CoachStudentmoney getLegalBalanceRecord(CoachCoursejoin coachCoursejoin);
    void subOneBalanceById(String coachStudentmoneyId);
    void addOneBalanceById(String coachStudentmoneyId);
    void insertCoachCourseJoin(CoachCoursejoin coachCoursejoin);
    void deleteCourseJoin(CoachCoursejoin coachCoursejoin);
}

